import { RouteConfig } from 'vue-router'
import Layout from '@/layout/index.vue'

const DeviceRoutes: RouteConfig = {
    path: '/device',
    component: Layout,
    redirect: '/device/index',
    name: 'deviceMgr',
    meta: {
        title: 'deviceMgr',
        icon: 'component'
    },
    children: [
        {
            path: 'index',
            component: () => import(/* webpackChunkName: "device_info" */ '@/views/device/info/index.vue'),
            name: 'DeviceIndex',
            meta: {
                title: 'deviceIndex',
                noCache: true
            }
        },
        {
            path: 'basic',
            component: () => import(/* webpackChunkName: "device_basic" */ '@/views/device/basic/index.vue'),
            name: 'DeviceBasic',
            meta: {
                title: 'deviceBasic',
                noCache: true
            }
        },
        {
            path: 'type',
            component: () => import(/* webpackChunkName: "device_type" */ '@/views/device/type/index.vue'),
            name: 'DeviceType',
            meta: {
                title: 'deviceType',
                noCache: true
            }
        },
        {
            path: 'color',
            component: () => import(/* webpackChunkName: "device-color" */ '@/views/device/color/index.vue'),
            name: 'ColorDemo',
            meta: {
                title: 'deviceColor',
                noCache: true
            }
        },
        {
            path: 'layout',
            component: () => import(/* webpackChunkName: "device-layout" */ '@/views/device/layout/index.vue'),
            name: 'LayoutDemo',
            meta: {
                title: 'deviceLayout',
                noCache: true
            }
        },
        {
            path: 'attr',
            component: () => import(/* webpackChunkName: "device-attr" */ '@/views/device/attr/index.vue'),
            name: 'AttrDemo',
            meta: {
                title: 'deviceAttr',
                noCache: true
            }
        }
        
    ]
}

export default DeviceRoutes
